package xyz.xmh.pattern.behavioral.mediatorpattern;

import java.time.LocalDateTime;
import java.time.format.DateTimeFormatter;
import java.time.format.FormatStyle;

/**
 * @author Administrator
 * <p>
 * 中介类
 */
public class ChatRoom {

    public static void showMessage(User user, String message) {
        System.out.println(user.getName() + "：" + message + "\t--" + LocalDateTime.now().format(DateTimeFormatter.ofLocalizedDateTime(FormatStyle.LONG)));
    }

}
